package com.snda.game.legend.service;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.snda.game.legend.dao.ActicleDao;
import com.snda.game.legend.entiy.Acticle;

@Service
@Transactional
public class ActicleService implements BaseService<Acticle> {
    @Resource
    private ActicleDao acticleDao;

    @Override
    public Acticle find(int id) {
        return acticleDao.query(Acticle.class, id);
    }

    @Override
    public Acticle modify(Acticle t) {

        return acticleDao.update(t);
    }

    @Override
    public void delete(Acticle t) {
        acticleDao.delete(t);
    }

    @Override
    public Acticle add(Acticle t) {
        return acticleDao.insert(t);
    }

    @Override
    public List<Acticle> find(String queryString) {
        return acticleDao.query(queryString);
    }

    public List<Acticle> findAll() {
        return acticleDao.findAll();
    }

    public List<Acticle> findAll(boolean limit) {

        return acticleDao.findAll(limit);
    }
}
